package com.unytech.project.entity.torrents.parameter;

import java.util.HashSet;
import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;

import com.unytech.project.entity.torrents.CommonEntity;

/**
 * 预警响应部门信息表
 * @author DolphinBoy
 * 记录预警响应部门信息
 */
@Entity 
@Table(name="Dept_B")
public class Dept_B extends CommonEntity {
	/** 部门编号 */
	@Id @Column(name="DeptCD", length=6, nullable=false)
	private String deptid;
	
	/** 部门名称 */
	@Column(name="DeptNM",length=20,nullable=false)
	private String deptname;
	
	/** 传真号码 */
	@Column(name="FaxCode",length=20)
	private String deptfaxcode;
	
	/** 广播编码 */
	@Column(name="BroadCast",length=100)
	private String deptbroadcast;
	
	/** 部门职责 */
	@Column(name="Duty",length=200)
	private String deptduty;

	@OneToMany(cascade={CascadeType.REFRESH,CascadeType.MERGE},fetch=FetchType.LAZY,mappedBy="deptid")
	private Set<Person_B> personb = new HashSet<Person_B>();
	
	
	public String getDeptid() {
		return deptid;
	}

	public void setDeptid(String deptid) {
		this.deptid = deptid;
	}

	public String getDeptname() {
		return deptname;
	}

	public void setDeptname(String deptname) {
		this.deptname = deptname;
	}

	public String getDeptfaxcode() {
		return deptfaxcode;
	}

	public void setDeptfaxcode(String deptfaxcode) {
		this.deptfaxcode = deptfaxcode;
	}

	public String getDeptbroadcast() {
		return deptbroadcast;
	}

	public void setDeptbroadcast(String deptbroadcast) {
		this.deptbroadcast = deptbroadcast;
	}

	public String getDeptduty() {
		return deptduty;
	}

	public void setDeptduty(String deptduty) {
		this.deptduty = deptduty;
	}

	public Set<Person_B> getPersonb() {
		return personb;
	}

	public void setPersonb(Set<Person_B> personb) {
		this.personb = personb;
	}
	
}
